﻿using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using Google.Protobuf;
using Google.Protobuf.Reflection;

namespace EggLink.DanhengServer.Proto
{
	// Token: 0x02000039 RID: 57
	[DebuggerDisplay("{ToString(),nq}")]
	public sealed class AddAvatarScNotify : IMessage<AddAvatarScNotify>, IMessage, IEquatable<AddAvatarScNotify>, IDeepCloneable<AddAvatarScNotify>, IBufferMessage
	{
		// Token: 0x170000B4 RID: 180
		// (get) Token: 0x0600028A RID: 650 RVA: 0x000084DF File Offset: 0x000066DF
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageParser<AddAvatarScNotify> Parser
		{
			get
			{
				return AddAvatarScNotify._parser;
			}
		}

		// Token: 0x170000B5 RID: 181
		// (get) Token: 0x0600028B RID: 651 RVA: 0x000084E6 File Offset: 0x000066E6
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageDescriptor Descriptor
		{
			get
			{
				return AddAvatarScNotifyReflection.Descriptor.MessageTypes[0];
			}
		}

		// Token: 0x170000B6 RID: 182
		// (get) Token: 0x0600028C RID: 652 RVA: 0x000084F8 File Offset: 0x000066F8
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		MessageDescriptor IMessage.Descriptor
		{
			get
			{
				return AddAvatarScNotify.Descriptor;
			}
		}

		// Token: 0x0600028D RID: 653 RVA: 0x000084FF File Offset: 0x000066FF
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public AddAvatarScNotify()
		{
		}

		// Token: 0x0600028E RID: 654 RVA: 0x00008508 File Offset: 0x00006708
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public AddAvatarScNotify(AddAvatarScNotify other) : this()
		{
			this.baseAvatarId_ = other.baseAvatarId_;
			this.reward_ = ((other.reward_ != null) ? other.reward_.Clone() : null);
			this.src_ = other.src_;
			this.isNew_ = other.isNew_;
			this._unknownFields = UnknownFieldSet.Clone(other._unknownFields);
		}

		// Token: 0x0600028F RID: 655 RVA: 0x0000856C File Offset: 0x0000676C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public AddAvatarScNotify Clone()
		{
			return new AddAvatarScNotify(this);
		}

		// Token: 0x170000B7 RID: 183
		// (get) Token: 0x06000290 RID: 656 RVA: 0x00008574 File Offset: 0x00006774
		// (set) Token: 0x06000291 RID: 657 RVA: 0x0000857C File Offset: 0x0000677C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint BaseAvatarId
		{
			get
			{
				return this.baseAvatarId_;
			}
			set
			{
				this.baseAvatarId_ = value;
			}
		}

		// Token: 0x170000B8 RID: 184
		// (get) Token: 0x06000292 RID: 658 RVA: 0x00008585 File Offset: 0x00006785
		// (set) Token: 0x06000293 RID: 659 RVA: 0x0000858D File Offset: 0x0000678D
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public ItemList Reward
		{
			get
			{
				return this.reward_;
			}
			set
			{
				this.reward_ = value;
			}
		}

		// Token: 0x170000B9 RID: 185
		// (get) Token: 0x06000294 RID: 660 RVA: 0x00008596 File Offset: 0x00006796
		// (set) Token: 0x06000295 RID: 661 RVA: 0x0000859E File Offset: 0x0000679E
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public AddAvatarSrcState Src
		{
			get
			{
				return this.src_;
			}
			set
			{
				this.src_ = value;
			}
		}

		// Token: 0x170000BA RID: 186
		// (get) Token: 0x06000296 RID: 662 RVA: 0x000085A7 File Offset: 0x000067A7
		// (set) Token: 0x06000297 RID: 663 RVA: 0x000085AF File Offset: 0x000067AF
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public bool IsNew
		{
			get
			{
				return this.isNew_;
			}
			set
			{
				this.isNew_ = value;
			}
		}

		// Token: 0x06000298 RID: 664 RVA: 0x000085B8 File Offset: 0x000067B8
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override bool Equals(object other)
		{
			return this.Equals(other as AddAvatarScNotify);
		}

		// Token: 0x06000299 RID: 665 RVA: 0x000085C8 File Offset: 0x000067C8
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public bool Equals(AddAvatarScNotify other)
		{
			return other != null && (other == this || (this.BaseAvatarId == other.BaseAvatarId && object.Equals(this.Reward, other.Reward) && this.Src == other.Src && this.IsNew == other.IsNew && object.Equals(this._unknownFields, other._unknownFields)));
		}

		// Token: 0x0600029A RID: 666 RVA: 0x00008638 File Offset: 0x00006838
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override int GetHashCode()
		{
			int num = 1;
			if (this.BaseAvatarId != 0U)
			{
				num ^= this.BaseAvatarId.GetHashCode();
			}
			if (this.reward_ != null)
			{
				num ^= this.Reward.GetHashCode();
			}
			if (this.Src != AddAvatarSrcState.AddAvatarSrcNone)
			{
				num ^= this.Src.GetHashCode();
			}
			if (this.IsNew)
			{
				num ^= this.IsNew.GetHashCode();
			}
			if (this._unknownFields != null)
			{
				num ^= this._unknownFields.GetHashCode();
			}
			return num;
		}

		// Token: 0x0600029B RID: 667 RVA: 0x000086C5 File Offset: 0x000068C5
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override string ToString()
		{
			return JsonFormatter.ToDiagnosticString(this);
		}

		// Token: 0x0600029C RID: 668 RVA: 0x000086CD File Offset: 0x000068CD
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void WriteTo(CodedOutputStream output)
		{
			output.WriteRawMessage(this);
		}

		// Token: 0x0600029D RID: 669 RVA: 0x000086D8 File Offset: 0x000068D8
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalWriteTo(ref WriteContext output)
		{
			if (this.BaseAvatarId != 0U)
			{
				output.WriteRawTag(24);
				output.WriteUInt32(this.BaseAvatarId);
			}
			if (this.reward_ != null)
			{
				output.WriteRawTag(34);
				output.WriteMessage(this.Reward);
			}
			if (this.Src != AddAvatarSrcState.AddAvatarSrcNone)
			{
				output.WriteRawTag(64);
				output.WriteEnum((int)this.Src);
			}
			if (this.IsNew)
			{
				output.WriteRawTag(72);
				output.WriteBool(this.IsNew);
			}
			if (this._unknownFields != null)
			{
				this._unknownFields.WriteTo(ref output);
			}
		}

		// Token: 0x0600029E RID: 670 RVA: 0x0000876C File Offset: 0x0000696C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public int CalculateSize()
		{
			int num = 0;
			if (this.BaseAvatarId != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.BaseAvatarId);
			}
			if (this.reward_ != null)
			{
				num += 1 + CodedOutputStream.ComputeMessageSize(this.Reward);
			}
			if (this.Src != AddAvatarSrcState.AddAvatarSrcNone)
			{
				num += 1 + CodedOutputStream.ComputeEnumSize((int)this.Src);
			}
			if (this.IsNew)
			{
				num += 2;
			}
			if (this._unknownFields != null)
			{
				num += this._unknownFields.CalculateSize();
			}
			return num;
		}

		// Token: 0x0600029F RID: 671 RVA: 0x000087E8 File Offset: 0x000069E8
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(AddAvatarScNotify other)
		{
			if (other == null)
			{
				return;
			}
			if (other.BaseAvatarId != 0U)
			{
				this.BaseAvatarId = other.BaseAvatarId;
			}
			if (other.reward_ != null)
			{
				if (this.reward_ == null)
				{
					this.Reward = new ItemList();
				}
				this.Reward.MergeFrom(other.Reward);
			}
			if (other.Src != AddAvatarSrcState.AddAvatarSrcNone)
			{
				this.Src = other.Src;
			}
			if (other.IsNew)
			{
				this.IsNew = other.IsNew;
			}
			this._unknownFields = UnknownFieldSet.MergeFrom(this._unknownFields, other._unknownFields);
		}

		// Token: 0x060002A0 RID: 672 RVA: 0x00008878 File Offset: 0x00006A78
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(CodedInputStream input)
		{
			input.ReadRawMessage(this);
		}

		// Token: 0x060002A1 RID: 673 RVA: 0x00008884 File Offset: 0x00006A84
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalMergeFrom(ref ParseContext input)
		{
			uint num;
			while ((num = input.ReadTag()) != 0U)
			{
				if (num <= 34U)
				{
					if (num == 24U)
					{
						this.BaseAvatarId = input.ReadUInt32();
						continue;
					}
					if (num == 34U)
					{
						if (this.reward_ == null)
						{
							this.Reward = new ItemList();
						}
						input.ReadMessage(this.Reward);
						continue;
					}
				}
				else
				{
					if (num == 64U)
					{
						this.Src = (AddAvatarSrcState)input.ReadEnum();
						continue;
					}
					if (num == 72U)
					{
						this.IsNew = input.ReadBool();
						continue;
					}
				}
				this._unknownFields = UnknownFieldSet.MergeFieldFrom(this._unknownFields, ref input);
			}
		}

		// Token: 0x040000D9 RID: 217
		private static readonly MessageParser<AddAvatarScNotify> _parser = new MessageParser<AddAvatarScNotify>(() => new AddAvatarScNotify());

		// Token: 0x040000DA RID: 218
		private UnknownFieldSet _unknownFields;

		// Token: 0x040000DB RID: 219
		public const int BaseAvatarIdFieldNumber = 3;

		// Token: 0x040000DC RID: 220
		private uint baseAvatarId_;

		// Token: 0x040000DD RID: 221
		public const int RewardFieldNumber = 4;

		// Token: 0x040000DE RID: 222
		private ItemList reward_;

		// Token: 0x040000DF RID: 223
		public const int SrcFieldNumber = 8;

		// Token: 0x040000E0 RID: 224
		private AddAvatarSrcState src_;

		// Token: 0x040000E1 RID: 225
		public const int IsNewFieldNumber = 9;

		// Token: 0x040000E2 RID: 226
		private bool isNew_;
	}
}
